<extend name="Public:base" />

<block name="content">
    <div class="row">
        <div class="col-lg-12">
            <h3 class="page-header"><em class="glyphicon glyphicon-cloud-upload"></em> 
            {$type}         
            </h3>
        </div>
        
    </div>

    <div class="row margin-botton">
        <div class="col-sm-6 column">
            <div class="btn-group btn-group-md">
                <button class="btn btn-default" type="button" onclick="doConfirmBatch('{:U('del', array('batchFlag' => 1))}', '确实要删除选择项吗？')"><em class="glyphicon glyphicon-remove-circle"></em> 删除</button>
            </div>
        </div>        
    </div>

    <div class="row">
        <div class="col-lg-12">
            <form action="" method="post" id="form_do" name="form_do">
                <div class="table-responsive">
                    <table class="table table-hover xyh-table-bordered-out">
                        <thead>
                            <tr class="active">
                                <th><input type="checkbox" id="check"></th>
                                <th>编号</th>
                                <th>发布人</th>
                                <th>评论|标题</th>
                                <th>模型</th>
                                <th>发布时间</th>
                                <th>ip</th>
                                <th class="text-right">操作</th>
                            </tr>
                        </thead>
                        <tbody>
                        <foreach name='vlist' item='v'>
                        <tr>
                            <td><input type="checkbox" name="key[]" value="{$v.id}"></td>
                            <td>{$v.id}</td>
                            <td><if condition="$v['username'] eq ''">{$v.email}<else/>{$v.username}</if></td>
                            <td class="aleft line160">
                                <p>内容：{$v.content}</p>
                                文档：{$v.title}[ID:{$v.postid}]</td>
                            <td>{$v.modelname}</if></td>
                            <td>{$v.posttime|date='Y-m-d H:i:s', ###}</td>
                            <td>{$v.ip}</td>                    
                            <td class="text-right">
                                <a href="{:U('edit',array('id' => $v['id']), '')}" class="label label-success">编辑</a>
                                <a href="javascript:;" onclick="toConfirm('{:U('del',array('id' => $v['id']), '')}', '确实要删除吗？')" class="label label-danger">删除</a>
                    
                            </td>
                        </tr>
                        </foreach>
                        </tbody>
                    </table>
                </div>
            </form>

            <div class="row clearfix">
                <div class="col-md-12 column">
                    <div class="xyh-page">
                        {$page}
                    </div>
                </div>
            </div>

            
        </div>
    </div>

    </block>